<template>
	<view>
		<cu-custom bgColor="bg-gradual-fff" isBack="true">
			<block slot="content">意见反馈</block> 
		</cu-custom>
		<u-loading-page :loading="true" loading-text="loading..." v-if="showLoading"></u-loading-page>
		<view v-show="!showLoading">
			<view class="viewbox"></view>
			<view class="help">
				<textarea v-model="description" placeholder-style="color:#cccccc" placeholder="请您留下姓名和手机号，我们这边会电话联系您"></textarea>
			</view>
			<view class="registera_e">
				<view class="registera_e_b" @click="help_post">立即提交</view>
			</view>
		</view>
	</view>
</template>
<script>
import request from '@/common/request.js';	
export default {
	data() {
		return {
			showLoading:false,
			description:'',
			uid:0,
		}
	},
	onShow(){
		this.uid=uni.getStorageSync('uid');
	},
	mounted() {
		
	},
	methods: {
		help_post(){
			let paramsList = {
				uid:this.uid,
				description:this.description
			}
			let optsList = {
				url: 'u-feedback',
				method: 'post'
			};
			let _this=this;
			request.httpTokenRequest(optsList, paramsList).then(res => {
				uni.hideLoading();
				uni.showToast({
					title: res.data.msg,
					icon:'none',
					duration: 2000
				});
				if(res.data.code == 200){
					uni.navigateBack();
				}
			});
		},
	}
}
</script>

<style  lang="scss" scoped>
	.help{
		width: 750rpx;
		height: 657rpx;
		background-color: #FFFFFF;
		padding: 47rpx 35rpx;
	}
	.help textarea{
		width: 680rpx;
		height: 557rpx;
		background: #FFFFFF;
		border: 2rpx solid #E5E5E5;
		padding: 30rpx 20rpx;
		font-size: 28rpx;
		font-family: PingFang SC;
		font-weight: 800;
		color: #000000;
	}
	.registera_e{
		width: 750rpx;
		height:90rpx;
		margin-top: 75rpx;
		
	}
	.registera_e_b{
		width: 600rpx;
		height: 90rpx;
		background: linear-gradient(-90deg, #E71102, #E71102);
		border-radius: 45rpx;
		margin: auto;
		font-size: 30rpx;
		font-family: PingFang SC;
		font-weight: 500;
		color: #FFFFFF;
		line-height: 90rpx;
		text-align: center;
	}
</style>
